﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace CSharpDay06__MVC_with_User_Input_.Models
{
    public static class DB
    {
        private static List<Shape> shapes;
        public static List<Shape> Shapes
        {
            get
            {
                if (shapes == null)
                {
                    shapes = new List<Shape>()
                    {
                        new Triangle() { Id = 1, Base = 10, Height = 30 },
                        new Triangle() { Id = 2, Base = 30, Height = 15 },
                        new Rectangle() { Id = 3, Length = 5, Width = 7 },
                        new Rectangle() { Id = 4, Length = 4, Width = 20 }
                    };
                }
                return shapes;
            }
            set
            {
                shapes = value;
            }
        }
    }
}

